<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@page isELIgnored="false" %>
<%@ include file="/WEB-INF/views/common/includes.jsp" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>

<c:if test="${empty form.application.id}">
	<h3><fmt:message key="section.admin.add.application.header"/></h3>	
</c:if>
<c:if test="${not empty form.application.id}">
	<h3><fmt:message key="section.admin.edit.application.header"/></h3>
</c:if>

<div class="span-16 last">			
  <form:form commandName="form" cssClass="inline" action="/${rc.locale.language}/admin/application" method="POST">
	<%@ include file="/WEB-INF/views/include/application_edit_fields.jsp" %>
	
	<div class="column span-4 prepend-12 last">
      <input class="submit" type="submit" value="<fmt:message key='button.save'/>" title="<fmt:message key='button.save'/>"/>
    </div>			
  </form:form>
</div>

<%--
			<c:if test="${empty app.id}">
				<h1><fmt:message key="app.add.section.header"/></h1>	
			</c:if>
			<c:if test="${not empty app.id}">
				<h1><fmt:message key="app.edit.section.header"/></h1>
			</c:if>

			
		<form:form commandName="app" action="/${rc.locale.language}/application" method="POST">
			<div class="form_settings">
				<form:hidden path="id"/>
								
				<!-- Name field -->
				<form:errors path="name" cssClass="ui-state-error"/>
				<p><span><fmt:message key="app.fields.name"/></span><form:input path="name" /></p>
				
				<!-- Description field -->
				<form:errors path="description" cssClass="ui-state-error"/>
				<p><span><fmt:message key="app.fields.description"/></span><form:input path="description" /></p>
				
				<!-- Company field -->
				<form:errors path="company" cssClass="ui-state-error"/>
				<p><span><fmt:message key="app.fields.company"/></span><form:input path="company" /></p>
				
				<!-- Redirect URI field -->
				<form:errors path="webServerRedirectUri" cssClass="ui-state-error"/>
				<p><span><fmt:message key="app.fields.webServerRedirectUri"/></span><form:input path="webServerRedirectUri" /></p>
				
				<p style="padding-top: 15px"><span>&nbsp;</span>
				<input class="submit" type="submit" value="<fmt:message key='generic.submit.message'/>" title="<fmt:message key='generic.submit.message'/>"/>
				</p>
			</div>
		</form:form>
--%>